package com.xdcplus.web.common.enums.base;

/**
 * 物料属性
 * @author Fish.Fei
 */

public enum BaseMtrlAttributeEnum {
    SM("SM", "自制件"),
    BI("BI", "外购件"),
    OS("OS", "委外件"),
    VP("VP", "虚拟件"),
    ;

    private String code;

    private String msg;

    public static String getMsg(String code) {
        for (BaseMtrlAttributeEnum ele : values()) {
            if(ele.getCode().equals(code)) {return ele.getMsg();}
        }
        return null;
    }

    BaseMtrlAttributeEnum(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }

}
